package lp.xian.materials.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 采购订单数据对象 lp_purchase_table
 *
 * @author ruoyi
 * @date 2023-08-06
 */
@Data
public class PurchaseTable extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 采购订单数据 */
    private Integer purchaseTableId;

    /** 采购订单id */
    @Excel(name = "采购订单id")
    private Integer purchaseId;

    /** 存货编码 */
    @Excel(name = "存货编码")
    private String purchaseOrderNo;

    /** 存货名称 */
    @Excel(name = "存货名称")
    private String purchaseTableName;


    /** 规格型号 */
    @Excel(name = "规格型号")
    private String purchaseTableSpeion;


    /** 存货名称 */
    @Excel(name = "单位")
    private String purchaseTableUnit;


    /** 数量 */
    @Excel(name = "数量")
    private Integer purchaseTableNum;

    /** 含税单价 */
    @Excel(name = "含税单价")
    private BigDecimal purchaseUnitPrice;

    /** 单价 */
    @Excel(name = "单价")
    private BigDecimal purchasePrice;

    /** 总价金额 */
    @Excel(name = "总价金额")
    private BigDecimal purchaseTotalPrice;

    /** 税额 */
    @Excel(name = "税额")
    private BigDecimal purchaseTaxPrice;

    /** 含税总金额 */
    @Excel(name = "含税总金额")
    private BigDecimal purchaseUnitTotalPrice;

    /** 税率 */
    @Excel(name = "税率")
    private BigDecimal purchaseTax;

    /** 计划到货日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "计划到货日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date purchaseDate;


    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)

                .append("purchaseTableSpeion", getPurchaseTableSpeion())
                .append("purchaseTableUnit", getPurchaseTableUnit())
                .append("purchaseTableId", getPurchaseTableId())
                .append("purchaseId", getPurchaseId())
                .append("purchaseOrderNo", getPurchaseOrderNo())
                .append("purchaseTableName", getPurchaseTableName())
                .append("purchaseTableNum", getPurchaseTableNum())
                .append("purchaseUnitPrice", getPurchaseUnitPrice())
                .append("purchasePrice", getPurchasePrice())
                .append("purchaseTotalPrice", getPurchaseTotalPrice())
                .append("purchaseTaxPrice", getPurchaseTaxPrice())
                .append("purchaseUnitTotalPrice", getPurchaseUnitTotalPrice())
                .append("purchaseTax", getPurchaseTax())
                .append("purchaseDate", getPurchaseDate())
                .toString();
    }
}
